package com.romadan.core.nonlinearanalys.fet.volterra.logic;

import com.romadan.utils.math.Complex;

public final class NodeType {
	private int node_id;
	private Complex voltage;
	private Complex current;
	
	public NodeType(int node_id) {
		this.node_id = node_id;
	}
	
	public int getId() {
		return node_id;
	}

	public Complex getVoltage() {
		return voltage;
	}

	public void setVoltage(Complex voltage) {
		this.voltage = voltage;
	}

	public Complex getCurrent() {
		return current;
	}

	public void setCurrent(Complex current) {
		this.current = current;
	}

	@Override
	public String toString() {
		return "NodeType [id = " + node_id + "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + node_id;
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		NodeType other = (NodeType) obj;
		if (node_id != other.node_id)
			return false;
		return true;
	}
	
	
}
